/* getters对象(Vuex中的计算属性) */
const getters = {
  sidebar: state => state.app.sidebar,
  device: state => state.app.device,
  // 用户登录的token
  token: state => state.user.token,
  // 用户的ID
  userId: state => state.user.userInfo.userId,
  // 用户的头像
  avatar: state => state.user.userInfo.staffPhoto,
  // 用户的名称
  name: state => state.user.userInfo.username,
  // 页面权限
  menu: state => state.menu.menu,
  // 按钮权限
  points: state => state.menu.points
}
/* 默认导出getters对象 */
export default getters
